
<table>
	<tr>
		<td  width="20%" align="right">流水号：</td>
		<td  width="30%">#{[$result.id]}({[$result.oper_t]})</td>
		<td  width="20%" align="right">状态：</td>
		<td  width="30%">{[$result.status_t]}</td>
	</tr>
	<tr>
		<td align="right">业务员：</td>
		<td>{[$result.emp_t]} [{[$result.emp]}]</td>
		<td align="right">日期：</td>
		<td>{[$result.date]}</td>
	</tr>
	<tr>
		<td align="right">事由：</td>
		<td colspan="3">{[$result.name]}</td>
	</tr>
	<tr>
		<td align="right">产品：</td>
		<td>{[$result.mold_t]}</td>
		<td align="right">类型：</td>
		<td>{[$result.type_t]}</td>
	</tr>
	<tr>
		<td align="right">客户：</td>
		<td colspan="3">{[$result.customer_x->fullname]}<br/>
		地址：{[$result.customer_x->address]} <!-- 网站：{[$result.customer_x->web]} --></td>
	</tr>
	<tr>
		<td align="right">联系人：</td>
		<td id="e_linkman" colspan="3"><!-- {[$result.customer_x->contact]} 手机：{[$result.customer_x->mobile]} 电话：{[$result.customer_x->tel]} 传真：{[$result.customer_x->fax]} 电邮：{[$result.customer_x->email]} --></td>
	</tr>
	<tr>
		<td align="right">金额：</td>
		<td colspan="3">（大写）{[$result.currency_t]} {[$result.amount|rmb]} （小写）{[$result.currency]} {[$result.amount|money]}</td>
	</tr>
	<tr>
		<td align="right">备注：</td>
		<td id="e_content" colspan="3">{[$result.content]}</td>
	</tr>
	<tr>
		<td colspan="4">
		{[include file="_file_view.tpl"]}
		</td>
	</tr>
</table>

<table style="margin-top: 10px">
	<tr>
		<th width="40">序号</th>
		<th>流水号</th>
		<th>产品</th>
		<th>事由</th>
		<th>币种</th>
		<th>应收</th>
		<th>实收</th>
		<th>开票日期</th>
		<th>到帐日期</th>		
		<th>状态</th>
		<th>备注</th>
	</tr>
	{[foreach name=outer key=key item=item from=$result.item]} 
	{[assign var="no" value="`$key+1`"]} 
	{[assign var="total"	value="`$total+$item.total`"]} 
	{[assign var="amount" value="`$amount+$item.amount`"]} 
	{[assign var="rmb" value="`$rmb+$item.rmb`"]}
	<tr align="center" onMouseOver="this.style.backgroundColor='#D2E4FC'" onMouseOut="this.style.backgroundColor=''">
		<td>{[$no]}</td>
		<td>{[$item.id]}</td>
		<td>{[$item.mold_t]}</td>
		<td>{[$item.name]}</td>
		<td>{[$item.currency_t]}
		<td>{[$item.total|money]}</td>
		<td>{[$item.amount|money]}</td>
		
		<td>{[$item.date1]}</td>
		<td>{[$item.date]}</td>
		<td>{[$item.status_t]}</td>
		<td id="item_content_{[$no]}">{[$item.content|truncate:21:"...":true]}</td>		
	</tr>
	{[/foreach]}
	<tr align="center" onMouseOver="this.style.backgroundColor='#D2E4FC'" onMouseOut="this.style.backgroundColor=''">
		<td colspan="5"></td>
		<td>{[$total|money]}</td>
		<td>{[$amount|money]}</td>
		<td></td>
		<td colspan="3"></td>
	</tr>
</table>

<script type="text/javascript" src="js/finance/payment/view.js?r={[$smarty.now]}"></script>
